#include<stdio.h>
int main (){
	void Eight (double x);
	double a;
	scanf("%d",&a);
	Eight (a);
	return 0;
} 
void Eight (double x){
	printf("%#o",x);
}
